package com.zha.boss.mvc.convert;

import com.zha.boss.dao.entity.PayWay;
import com.zha.boss.mvc.models.vo.PayWayVo;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.Mappings;

import java.util.List;

/**
 * @Author: zha
 * @CreateTime: 2024年09月15日 14:32
 */
@Mapper(componentModel = "spring",uses = {UserConvert.class})
public interface PayWayConvert {
    List<PayWayVo> toListPayWayVo(List<PayWay> payWayList);
    @Mappings({
            @Mapping(source = "editTime", target = "editTime", dateFormat = "yyyy-MM-dd HH:mm:ss"),
            @Mapping(source = "status", target = "status",qualifiedByName = "transStatus"),
            @Mapping(source="payProductCode",target="productCode")
    })
    PayWayVo toPayWayVo(PayWay payWay) ;
}
